package com.yuedou.api.entity.wxuser;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

@Data
@TableName(value = "wx_user")
public class User implements Serializable {
    @TableId(type = IdType.AUTO)
    private Integer id;

    private String userNo;

    private String nickName;

    private String realName;

    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private String phoneNum;

    /**
     *  会员余额支付密码
     */
    private String payPwd;

    /**
     *
     */
    private Integer payPwdErrorCount;

    /**
     *
     */
    private Date lastPwdErrorTime;

    /**
     * 来自平台（wx/dy）
     */
    private String platform;

    private String faceUrl;

    private String province;

    private String city;

    private String district;

    private String sessionKey;

    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date lastActiveTime;

    private String lastLoginIp;

    private String openId;

    private String unionId;

    private Long sysUserId;

    private Integer userType;

    private Integer isAdmin;

    private String token;

    private Integer sex;

    private BigDecimal lng;

    private BigDecimal lat;

    /**
     * 个人二维码
     */
    private String qrCode;


    @TableField(exist = false)
    private Double distance;
}
